package snooker.scoreboard;

import android.content.res.Resources;
import android.graphics.Color;
import android.view.View.OnClickListener;
import android.widget.TextView;

public class TextCheckBox {

	private boolean checked = false;
	private TextView textV;
	
	public TextCheckBox(Resources r, TextView textV) {
		this.textV = textV;
	}
	
	public boolean isChecked() {
		return checked;
	}

	public void setChecked(boolean checked) {
		this.checked = checked;
		if (checked) {
			textV.setBackgroundColor(Color.BLUE);
		} else {
			textV.setBackgroundColor(Color.BLACK);
		}
	}
	
	public void setOnClickListener(OnClickListener ocl) {
		textV.setOnClickListener(ocl);
	}
}
